alert: Send alert for ha'ed vm's#5664
Conversation
DaanHoogland
left a comment
There was a problem hiding this comment.
clgtm, but would the subject exactly the same as the content be helpful? can we add more info to the mail content?
@DaanHoogland if you have any content then let me know.. i can add that |
source and target host? time down? time up? down time duration? |
|
@blueorangutan package |
|
@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✖️ el7 ✔️ el8 ✖️ debian ✖️ suse15. SL-JID 1723 |
|
@blueorangutan package |
|
@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✔️ suse15. SL-JID 1771 |
|
@blueorangutan package |
|
@rohityadavcloud a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✖️ suse15. SL-JID 2039 |
GabrielBrascher
left a comment
There was a problem hiding this comment.
Thanks for the PR @ravening.
I've proposed a few changes that, in my opinion, can make this PR even more helpful :-)
|
|
||
| VMInstanceVO started = _instanceDao.findById(vm.getId()); | ||
| if (started != null && started.getState() == VirtualMachine.State.Running) { | ||
| String message = String.format("HA on VM: %s", started.getHostName()); |
There was a problem hiding this comment.
I like the idea of enhancing the alerts.
What do you think of changing from Ha on VM: VM Name to Ha Starting VM: VM Name (i-2-13477-VM).
Thus, making it String.format("HA on VM: %s (%s)", started.getHostName(), started.getInstanceName());.
There was a problem hiding this comment.
@ravening Do you want to add instance name to the alert message (as advised)?
| VMInstanceVO started = _instanceDao.findById(vm.getId()); | ||
| if (started != null && started.getState() == VirtualMachine.State.Running) { | ||
| String message = String.format("HA on VM: %s", started.getHostName()); | ||
| s_logger.info("VM is now restarted: " + vmId + " on " + started.getHostId()); |
There was a problem hiding this comment.
Taking the opportunity, what do you think of enhancing also the INFO log message?
As a suggestion, it could be logged something as the following:
HA is now restarting VM instance {id: "123", name: "VM Name", uuid: "1234.....abc", type="User"} on Host [{id: "1", name: "host.name", uuid: "ABC...123", type="Routing"}]
With the following code changes:
| s_logger.info("VM is now restarted: " + vmId + " on " + started.getHostId()); | |
| HostVO hostVmHasStarted = _hostDao.findById(started.getHostId()); | |
| s_logger.info(String.format("HA is now restarting %s on %s", started, hostVmHasStarted)); |
|
@blueorangutan package |
|
@DaanHoogland a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✖️ suse15. SL-JID 2157 |
|
@blueorangutan test |
1 similar comment
|
@blueorangutan test |
|
@sureshanaparti a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
|
Trillian test result (tid-2845)
|
|
HI @ravening Can you address outstanding comments. Thanks. |
|
Ping @ravening |
When ha is performed on vm's send the alert for it so that its for admins to know which vm's got ha'ed else its time consuming to get those details from logs
|
@blueorangutan package |
|
@nvazquez a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✖️ el7 ✖️ el8 ✖️ debian ✔️ suse15. SL-JID 2545 |
|
@blueorangutan package |
|
@nvazquez a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress. |
|
Packaging result: ✔️ el7 ✖️ el8 ✔️ debian ✔️ suse15. SL-JID 2647 |
|
@blueorangutan package |
|
@nvazquez a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result: ✖️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 2895 |
|
@blueorangutan package |
|
@nvazquez a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 2898 |
|
@blueorangutan test |
|
@nvazquez a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
|
Trillian test result (tid-3628)
|
Description
When ha is performed on vm's send the alert for it so that
its for admins to know which vm's got ha'ed else its time
consuming to get those details from logs
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity